<template>
  <div class="app">
    <!-- 路由出口 -->
    <router-view></router-view>
    <!-- 底部栏每一项
    van-tabbar
        placehoder----底部生成占位元素
        route--------开启路由模式
        actiove-color---默认不触发颜色
    van-tabbar-item
     -->
    <van-tabbar
      v-model="active"
      active-color="#e40137"
      inactive-color="#B4B4BD"
      route
      placeholder
      v-show="$route.meta.showTabbar"
    >
      <van-tabbar-item to="/Company" icon="shop-o">
        <span>公司</span>
        <template #icon>
          <i class=" iconfont iconicon_footbar_gs_sel"></i>
        </template>
      </van-tabbar-item>
      <van-tabbar-item to="/Question" icon="search">
        <span>刷题</span>
        <template #icon>
          <i class="iconfont iconicon_footbar_st_nor"></i>
        </template>
      </van-tabbar-item>
      <van-tabbar-item to="/Find" icon="friends-o">
        <span>发现</span>
        <template #icon>
          <i class="iconfont iconicon_footbar_fx_nor"></i>
        </template>
      </van-tabbar-item>
      <van-tabbar-item to="/My" icon="setting-o">
        <span>我的</span>
        <template #icon>
          <i class="iconfont iconicon_footbar_wode_nor"></i>
        </template>
      </van-tabbar-item>
    </van-tabbar>
  </div>
</template>
<script>
export default {
  data () {
    return {
      active: 0
    }
  }
}
</script>
<style lang="less">
.van-tabbar {
  .iconfont {
    font-size: 28px;
  }
}
</style>
